// 用户相关接口
import request from '@/utils/request'

export function login (email, password) {
  const params = {}
  params.email = email
  params.password = password
  return request({
    url: '/api/auth/login',
    method: 'post',
    data: params
  })
}

export function getInfo () {
  return request({
    url: '/api/user',
    method: 'get'
  })
}

export function logout () {
  return request({
    url: '/api/auth/logout',
    method: 'post'
  })
}
